import request from '@/utils/request'

// 查询公众参与列表
export function listParticipation(query) {
  return request({
    url: '/participation/participation/list',
    method: 'get',
    params: query
  })
}

// 查询公众参与详细
export function getParticipation(id) {
  return request({
    url: '/participation/participation/' + id,
    method: 'get'
  })
}

// 新增公众参与
export function addParticipation(data) {
  return request({
    url: '/participation/participation/add',
    method: 'post',
    data: data
  })
}

// 修改公众参与
export function updateParticipation(data) {
  return request({
    url: '/participation/participation',
    method: 'put',
    data: data
  })
}

// 删除公众参与
export function delParticipation(id) {
  return request({
    url: '/participation/participation/' + id,
    method: 'delete'
  })
}

// 新增
export function addFrom(data) {
  return request({
    url: '/participation/participation/add',
    method: 'post',
    data: data
  })
}

//二维码接口
export function getEwmCode(query) {
  return request({
    url: '/participation/participation/selectUrl',
    method: 'get',
    params: query
  })
}

//不采纳
export function notAdopt(data) {
  return request({
    url: '/participation/participation/accept ',
    method: 'post',
    data: data
  })
}
